# 1. create a new chain in filter
# --------------------------------------------------
c=ChainAaa
sudo iptables --table filter --new-chain $c


# 2. enable the chain (by inserting a JUMP rule at the beginning of the chain)
# 🦜 : Let's use append, be kind, be nice
# --------------------------------------------------
r1="--jump $c"
sudo iptables --table filter --append INPUT $r1


# ==================================================
# ipv6
#
# 🦜 we wanna accept all the traffic from fd00::1234:0/126, because that's how
# our agent talk to the server
# --------------------------------------------------
r1="--source fd00::1234:0/126 --jump ACCEPT"
sudo ip6tables --table filter --append INPUT $r1
r1="--jump $c"
sudo ip6tables --table filter --new-chain $c
sudo ip6tables --table filter --append INPUT $r1
